Previous Book Contents Book Index Next

Inside Macintosh: 3D Graphics Programming With QuickDraw 3D /
Chapter 20 - QuickDraw 3D Mathematical Utilities / QuickDraw 3D Mathematical Utilities Reference
QuickDraw 3D Mathematical Utilities / Adding and Subtracting Vectors


Q3Vector2D_Add

You can use the Q3Vector2D_Add function to add two two-dimensional vectors.

TQ3Vector2D *Q3Vector2D_Add (
const TQ3Vector2D *v1, 
const TQ3Vector2D *v2, 
TQ3Vector2D *result);
v1
A two-dimensional vector.
v2
A two-dimensional vector.
result
On exit, the sum of v1 and v2.
DESCRIPTION
The Q3Vector2D_Add function returns, as its function result and in the result parameter, the two-dimensional vector that is the sum of the two vectors v1 and v2. Note that on entry the result parameter can be the same as either v1 or v2 (or both).


Previous Book Contents Book Index Next

© Apple Computer, Inc.
11 JUL 1996